DROP TABLE IF EXISTS jms_ods.yl_lmdm_sys_network_electronic;
CREATE EXTERNAL TABLE jms_ods.yl_lmdm_sys_network_electronic(
 ID bigint comment "主键",  --NUMBER(11)
 NETWORK_ID bigint comment "网点主键",  --NUMBER(11)
 DELIVERY_SHAPE bigint comment "收派件围栏-形状 1多边形 2圆形",  --NUMBER(11)
 DELIVERY_TYPE int comment "1收件  2派件",  --NUMBER(6)
 G_ID string comment "高德地图主键",  --NVARCHAR2(50)
 G_NAME string comment "高德地图围栏名称",  --NVARCHAR2(50)
 G_CENTER string comment "圆形围栏中心点",  --NVARCHAR2(255)
 G_POINTS string comment "电子围栏坐标",  --CLOB
 G_RADIUS string comment "圆形围栏半径",  --NVARCHAR2(255)
 G_VALID_TIME timestamp comment "高德地图-过期日期",  --DATE
 G_CREATE_TIME timestamp comment "高德地图- 围栏创建时间",  --DATE
 EXPIRY_DATE timestamp comment "失效日期",  --DATE
 CREATE_BY bigint comment "创建人ID",  --NUMBER(11)
 UPDATE_BY bigint comment "更新人ID",  --NUMBER(11)
 CREATE_BY_NAME string comment "创建人姓名",  --NVARCHAR2(50)
 UPDATE_BY_NAME string comment "更新人姓名",  --NVARCHAR2(50)
 CREATE_TIME timestamp comment "创建时间",  --DATE
 UPDATE_TIME timestamp comment "更新时间",  --DATE
 NETWORK_TYPE_ID bigint comment "网点类型"  --NUMBER(11)
 )
 COMMENT '网点电子围栏'
 PARTITIONED BY (dt STRING COMMENT '更新/创建日期 (yyyy-MM-dd)')
 STORED AS PARQUET
 LOCATION '/dw/hive/jms_ods.db/external/yl_lmdm_sys_network_electronic'
 TBLPROPERTIES (
 'discover.partitions'='false',
 'parquet.column.index.access'='true'
 );

MSCK REPAIR TABLE jms_ods.yl_lmdm_sys_network_electronic;